import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { RouterModule } from '@angular/router';
import { SharedModule } from '../../../shared/shared.module';
import { PageTagComponent } from './page.tag';
import { DispatchListComponent } from './dispatchList.component';
import { OperaModalComponent } from './operaModal.component';
import { SecurityProblemModalComponent } from './securityProblemModal.component';
import { WorkareaDetailComponent } from './workareaDetail.component';
import { StationDetailComponent } from './stationDetail.component';
import { ExecutionDetailComponent } from './executionDetail.component';


import { TableComponent } from './table.component';

@NgModule({
  imports: [
    CommonModule,
    SharedModule,
    RouterModule.forChild([
      { path: 'workarea', component: PageTagComponent, data: { title: '作业工单-编制' } },
      { path: 'station', component: PageTagComponent, data: { title: '作业工单-审核' } },
      { path: 'seg', component: PageTagComponent, data: { title: '作业工单-审批' } },
      { path: 'export', component: PageTagComponent, data: { title: '作业工单-导出' } },
      { path: 'execution', component: PageTagComponent, data: { title: '完成情况反馈' } },
      { path: 'workareaDetail', component: WorkareaDetailComponent, data: { title: '作业工单编制-详情' } },
      { path: 'stationDetail', component: StationDetailComponent, data: { title: '作业工单审核-详情' } },
      { path: 'executionDetail', component: ExecutionDetailComponent, data: { title: '完成情况反馈-详情' } },
      { path: '**', redirectTo: 'workarea' }
    ])
  ],
  declarations: [DispatchListComponent, OperaModalComponent, WorkareaDetailComponent, StationDetailComponent, SecurityProblemModalComponent, ExecutionDetailComponent, PageTagComponent, TableComponent],
  exports: [RouterModule]
})
export class DispatchListModule { }
